
import java.lang.RuntimeException;

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author legyoroz
 */
public class Largest {
     public static int Largest(int[]list) {
      try{
       int index, max=list[0];
       for(index=0;index<list.length;index++){
        if(list[index]>max){
            max=list[index];
        }
         
       }
return max;
    }
     catch(ArrayIndexOutOfBoundsException e){
        return 1;
     }

     }

}

